package utils;

public class Shuffler {

	public String shuffle(String toShuffle) {

		char[] charAray = toShuffle.toCharArray();
		char temp;

		for (int i = 0; i < toShuffle.length(); i++) {
			temp = charAray[i];
			int index = (int) (Math.random() * (toShuffle.length() - i));
			charAray[i] = charAray[i + index];
			charAray[i + index] = temp;
		}

		return new String(charAray);
	}
}
